
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page isELIgnored="false" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>登录</title>
<link type="text/css" rel="stylesheet" href="${pageContext.request.contextPath}/static/css/login.css" />
    <link rel="stylesheet" href="${pageContext.request.contextPath}/static/css/message2.css">

</head>

<body>
<input type="hidden" id="flag" value="${flag}">
<div class="main">
  <div class="main0">
     <div class="main_left">
        <img src="${pageContext.request.contextPath}/static/images/login-image-3.png" class="theimg"/>
        <img src="${pageContext.request.contextPath}/static/images/login-image-2.png" class="secimg"/>
        <img src="${pageContext.request.contextPath}/static/images/login-image-1.png" class="firimg"/>
     </div>
     <div class="main_right">
        <div class="main_r_up">
            <img src="${pageContext.request.contextPath}/static/images/user.png" />
            <div class="pp">登录</div>
        </div>
        <div class="sub"><p>还没有账号？<a href="${pageContext.request.contextPath}/register.jsp"><span class="blue">立即注册</span></a></p></div>
       <form action="${pageContext.request.contextPath}/user/loginUser" method="post">
           <div class="txt">
            <span style="letter-spacing:8px;">用户名:</span>
            <input name="account" type="text" class="txtphone" placeholder="请输入注册邮箱账号"/>
        </div>
        <div class="txt">
            <span style="letter-spacing:4px;">登录密码:</span>
            <input name="password" type="text" class="txtphone" placeholder="请输入登录密码"/>
        </div>
     <input type="submit" class="xiayibu" value="登录">
       </form>
     </div>
  </div>
</div>
</body>
<script type="text/javascript" src="${pageContext.request.contextPath}/static/js/jquery-3.5.1.min.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/static/js/message.js"></script>
<script type="text/javascript">
    $(document).ready(function () {
        var height=$(document).height();
        $('.main').css('height',height);
    })

    $(function (){
        var flag=$("#flag").val();
        if (flag=="succeed"){
            $.message({
                message: "注册成功",
                type: "success",
                time:'4000',
                showClose:true
            });
        }else if (flag=="fail"){
            $.message({
                message: "用户名或密码错误",
                type: "error",
                time:'4000',
                showClose:true
            });
        }
    });
</script>
</html>
